<?php
// Luu ten style hien thoi
$v_current_style_name = "odd_row";
// Luu ten style tiep theo
$v_next_style_name = "round_row";
$v_goto_url	="index.php";
$v_count = sizeof($arr_all_af_add);
?>
<!-- Bat cac phim: F12=false; Insert=true; Delete=true, ESC=false; Enter=false -->
<div id="hotkey" onKeyDown="javascript:process_hot_key(false,true,true,false,false);">
<!--bang chua tieu de cua form-->
<table width="100%" cellpadding="0" cellspacing="0">
	<tr class="normal_title">
		<form action="index.php" name="f_dsp_all_af_for_adding" method="post">
		<td width="100%" class="normal_title"><?php echo CONST_AF_LIST_TITLE;?></td>
		<input type="hidden" name="hdn_af_id" value="<?php echo $v_af_id;?>">
	</tr>
	<tr><td height="5"></td></tr>
</table>
<div style="overflow: auto; width: 100%; height:<?php echo _CONST_HEIGHT_OF_LIST?>;padding-left:0px;margin:0px; background-color:white;">
<table width="100%" class="list_table2" cellpadding="0" cellspacing="0" >
	<col width="5%"><col width="90%">
	<tr class = "header">
		<td width="100%" colspan="10"></td>
	</tr><?php 		
	if($v_count>0){
		for($i=0;$i<$v_count;$i++){
			$v_current_af_add_id = $arr_all_af_add[$i][0]; 
			$v_af_add_name = $arr_all_af_add[$i][1];
			if ($v_current_style_name == "odd_row"){
				$v_current_style_name = "round_row";
			}else{
				$v_current_style_name = "odd_row";
			}?>
			<tr class="<?php echo $v_current_style_name; ?>">
				<td>
					<input type="checkbox" name="chk_af_add_id" value="<?php echo $v_current_af_add_id;?>">
				</td>
				<td class="normal_label" align="left"><?php echo $v_af_add_name; ?></td>
			</tr><?
		}
	}
	if ($v_current_style_name == "odd_row"){
		$v_next_style_name = "round_row";
	}else{
		$v_next_style_name = "odd_row";
	}
	echo _add_empty_row($v_count,_CONST_NUMBER_OF_ROW_PER_LIST,$v_current_style_name,$v_next_style_name,2);?>
</table>
</div>
<!--Table chua cac button-->
<table align="center">
	<tr><td height="15"></td></tr>
	<tr>
		<td>
			<input type="button" value="<?php echo _CONST_SELECT_BUTTON;?>" style="width:75px " name="btn_select" class="normal_button" onClick="add_af()">&nbsp;&nbsp;
			<input type="button" value="<?php echo _CONST_BACK_BUTTON;?>" style="width:75px " name="btn_delete" class="normal_button" onClick="window.close();">
		</td>
	</tr>
</table>
</div id="hotkey">
</form>
